#!/usr/bin/env python3
# -*- coding: utf-8 -*-

def findMaxMin(num):
	min = max = num[0]
	for i in range(len(num)):
		if num[i] >= max:
			max = num[i]
		if num[i] <= min:
			min = num[i]
	return min,max
	
list = [1,2,334,34,53,-88,999]
result = findMaxMin(list)	
print(result)